* Stata/MP 13.1

log using "HinkleNelsonHazelton_JLC2019_replication.log"

use "HinkleNelsonHazelton_JLC2019_replication_data.dta", clear

tab split_outcome if unified == 1
tab split_outcome if unified == 0
drop if split_outcome == 1

***Panel Effects Exist in our Data
tab dv2b unified, col

*Calculate how many fewer counter-ideological rulings there would be
*if split panels acted the same as unfied panels 
display 8903 * 0.11

tab unified
drop if unified == 1


*** Summary Statistics
sum cjAge probFutPan sameCityCJ cjCoTen ebDist certDist

*Model: Results in Table 3
probit dv2b cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen ebDist certDist alignEnBanc alignSct cjAlignLC amicus civil_rights per_curiam juris  b9.circuit 
estimates store mod0
estat ic
*ssc install pre
pre mod0
test cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen ebDist certDist alignEnBanc alignSct cjAlignLC amicus civil_rights per_curiam juris, mtest(bonferroni)

probit dv2b cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen c.cjAlignLC##c.ebDist c.cjAlignLC##c.certDist amicus civil_rights per_curiam juris  b9.circuit 
estimates store mod

***Robustness Checks
** FN23: No fixed effects for circuit
probit dv2b cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen ebDist certDist alignEnBanc alignSct cjAlignLC amicus civil_rights per_curiam juris 
test cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen ebDist certDist alignEnBanc alignSct cjAlignLC amicus civil_rights per_curiam juris, mtest(bonferroni)

*FN24 and Table 5, model with additional variables 
probit dv2b cirDissRateLag3 cjAge cjAge2 cjSenior caseload100  probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD majSubExp cjT14 majT14 cjLongestTen cjShortestTen cjAlignLC ebDist certDist alignEnBanc alignSct  amicus civil_rights per_curiam juris  b9.circuit 
estimates store modRobust
estat ic
pre modRobust
test cirDissRateLag3 cjAge cjAge2 cjSenior caseload100  probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD majSubExp cjT14 majT14 cjLongestTen cjShortestTen cjAlignLC ebDist certDist alignEnBanc alignSct amicus civil_rights per_curiam juris , mtest(bonferroni)

*FN 24, Model adding just Age squared
probit dv2b cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen ebDist certDist alignEnBanc alignSct cjAlignLC amicus civil_rights per_curiam juris  b9.circuit cjAge2
estat ic
test cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen ebDist certDist alignEnBanc alignSct cjAlignLC amicus civil_rights per_curiam juris cjAge2, mtest(bonferroni)

*FN 24 Model adding just dissent rate lagged
probit dv2b cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen ebDist certDist alignEnBanc alignSct cjAlignLC amicus civil_rights per_curiam juris  b9.circuit cirDissRateLag3
estat ic
test cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen ebDist certDist alignEnBanc alignSct cjAlignLC amicus civil_rights per_curiam juris cirDissRateLag3, mtest(bonferroni)

*FN 24 Model adding just adding caseload
probit dv2b cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen ebDist certDist alignEnBanc alignSct cjAlignLC amicus civil_rights per_curiam juris  b9.circuit caseload100
estat ic
test cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen ebDist certDist alignEnBanc alignSct cjAlignLC amicus civil_rights per_curiam juris caseload100, mtest(bonferroni)

*FN 24 Model adding just majority expertise and majority T14
probit dv2b cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen ebDist certDist alignEnBanc alignSct cjAlignLC amicus civil_rights per_curiam juris  b9.circuit majSubExp majT14
estat ic
test cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen ebDist certDist alignEnBanc alignSct cjAlignLC amicus civil_rights per_curiam juris majSubExp majT14, mtest(bonferroni)

*** Quantities reported in the text of the Results section

*Change in age from 25% to 75%
estimates restore mod
margins,  at(sameCityCJ=0 cjSenior=0 cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=(56 70)  probFutPan=0.2 cjCoTen=5 ebDist=0.162 certDist=0.246 cjAlignLC=(0) amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample post contrast(atcontrast(ar._at))

*Change in cotenure from 25% to 75%
estimates restore mod
margins,  at(sameCityCJ=0 cjSenior=0 cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=63  probFutPan=0.2 cjCoTen=(0 11) ebDist=0.162 certDist=0.246 cjAlignLC=(0) amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample post contrast(atcontrast(ar._at))

*Change in certDist from 25% to 75%
estimates restore mod
margins,  at(sameCityCJ=0 cjSenior=0 cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=63  probFutPan=0.2 cjCoTen=5 ebDist=0.162 certDist=(0.117 0.373) cjAlignLC=(0) amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample post contrast(atcontrast(ar._at))


*** Quantities in Figure 2: Marginal effects of distance to higher court when aligned with lower court and not
estimates restore mod
margins, dydx(ebDist) at(sameCityCJ=0 cjSenior=0 cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=63 probFutPan=0.2 cjCoTen=5 certDist=0.246 cjAlignLC=0 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample
margins, dydx(ebDist) at(sameCityCJ=0 cjSenior=0 cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=63 probFutPan=0.2 cjCoTen=5 certDist=0.246 cjAlignLC=1 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample

estimates restore mod
margins, dydx(certDist) at(sameCityCJ=0 cjSenior=0 cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=63  probFutPan=0.2 cjCoTen=5 ebDist=0.162 cjAlignLC=0 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample
margins, dydx(certDist) at(sameCityCJ=0 cjSenior=0 cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=63  probFutPan=0.2 cjCoTen=5 ebDist=0.162 cjAlignLC=1 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample


*** Table 4
** F-tests
estimates restore mod
*Acquiescence Only
test cjAge cjSenior 
*Deliberation Only
test cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen 
*Strategy
test ebDist certDist cjAlignLC
test ebDist certDist

** Pred. Prob, Weak counterjudge
estimates restore mod
*Acquiescence Only
margins, at(sameCityCJ=0 cjSenior=1 cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=70  probFutPan=0.2 cjCoTen=5 ebDist=0.162 certDist=0.246 cjAlignLC=0 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample

*Deliberation Only
margins, at(sameCityCJ=0 cjSenior=0 cjCirDes=0 cjDJ=0 cjShortestTen=1 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=63  probFutPan=0.2 cjCoTen=0 ebDist=0.162 certDist=0.246 cjAlignLC=0 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample

*Strategy, with Alignment
margins, at(sameCityCJ=0 cjSenior=0 cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=63  probFutPan=0.2 cjCoTen=5 ebDist=0.041 certDist=0.116 cjAlignLC=0 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample

*Strategy, without Alignment
margins, at(sameCityCJ=0 cjSenior=0 cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=63  probFutPan=0.2 cjCoTen=5 ebDist=0.041 certDist=0.116 cjAlignLC=0 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample

** Pred. Prob, Strong counterjudge
*Acquiescence Only
margins, at( sameCityCJ=0 cjSenior=0  cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=56  probFutPan=0.2 cjCoTen=5 ebDist=0.162 certDist=0.246 cjAlignLC=0 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample

*Deliberation Only
margins, at(sameCityCJ=0 cjSenior=0 cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=1 cjProsPD=1 cjT14=1 cjAge=63  probFutPan=0.2 cjCoTen=11 ebDist=0.162 certDist=0.246 cjAlignLC=0 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample

*Strategy, with Alignment
margins, at(sameCityCJ=0 cjSenior=0 cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=63  probFutPan=0.2 cjCoTen=5 ebDist=0.361 certDist=0.373 cjAlignLC=1 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample
 
*Strategy, without Alignment
margins, at(sameCityCJ=0 cjSenior=0 cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=63  probFutPan=0.2 cjCoTen=5 ebDist=0.361 certDist=0.373 cjAlignLC=0 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample


**In text Discussion and Conclusions Section
estimates restore mod
** Predicted probabilities moving Acquiesence and Deliberation and Strategy variables from low to high (when not aligned)
* Low, Weak
margins, at(sameCityCJ=0 cjSenior=1  cjCirDes=1 cjDJ=1 cjShortestTen=1 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=70  probFutPan=0.143 cjCoTen=0 ebDist=0.041 certDist=0.116 cjAlignLC=0 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample
* High, Strong
margins, at(sameCityCJ=1 cjSenior=0  cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=1 cjProsPD=1 cjT14=1  cjAge=56  probFutPan=0.25 cjCoTen=11 ebDist=0.361 certDist=0.373 cjAlignLC=0 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample

** Predicted probabilities moving Acquiesence and Deliberation and Strategy variables from low to high (when aligned)
** Low, Weak
margins, at(sameCityCJ=0 cjSenior=1  cjCirDes=1 cjDJ=1 cjShortestTen=1 cjLongestTen=0 cjProsPD=0 cjT14=0 cjAge=70  probFutPan=0.143 cjCoTen=0 ebDist=0.041 certDist=0.116 cjAlignLC=1 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample
** High, Strong
margins, at(sameCityCJ=1 cjSenior=0  cjCirDes=0 cjDJ=0 cjShortestTen=0 cjLongestTen=1 cjProsPD=1 cjT14=1  cjAge=56  probFutPan=0.25 cjCoTen=11 ebDist=0.361 certDist=0.373 cjAlignLC=1 amicus=0 civil_rights=0 per_curiam=0 circuit=9 juris=1) noesample

** PRE
probit dv2b cjAge cjSenior
pre
probit dv2b cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen
pre
probit dv2b ebDist certDist cjAlignLC
pre
probit dv2b ebDist certDist
pre



***Table 6
probit dv2b cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen cjAlignLC ebDist certDist alignEnBanc alignSct amicus civil_rights per_curiam juris  b9.circuit if pan_num_gop == 2
pre
estat ic
test cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen cjAlignLC ebDist certDist alignEnBanc alignSct amicus civil_rights per_curiam juris, mtest(bonferroni)
estimates store modR

probit dv2b cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen cjAlignLC ebDist certDist alignEnBanc alignSct amicus civil_rights per_curiam juris  b9.circuit if pan_num_gop == 1
pre
estat ic
test cjAge cjSenior probFutPan sameCityCJ cjCirDes cjDJ cjCoTen cjProsPD cjT14 cjLongestTen cjShortestTen cjAlignLC ebDist certDist alignEnBanc alignSct amicus civil_rights per_curiam juris, mtest(bonferroni)
estimates store modD

log close
